package com.caishi.lkx.user.vo;

import cn.hutool.core.bean.BeanUtil;
import com.caishi.lkx.user.model.ActionRoleModel;
import com.caishi.lkx.user.model.AgentUserModel;
import com.caishi.lkx.user.model.LoginExpandModel;
import com.caishi.lkx.user.model.PositionModel;
import com.fasterxml.jackson.annotation.JsonIgnore;

import lombok.Getter;
import lombok.Setter;

import java.util.List;

/**
 * @author by keray
 * date:2021/4/26 2:59 下午
 */
@Getter
@Setter
public class AgentUserListVo extends AgentUserModel {
    public static AgentUserListVo model2Vo(AgentUserModel model) {
        AgentUserListVo vo = new AgentUserListVo();
        BeanUtil.copyProperties(model, vo);
        return vo;
    }

    @JsonIgnore
    private List<PositionModel> positions;

    @JsonIgnore
    private List<ActionRoleModel> roles;

    private List<String> roleNames;
    private List<String> positionNames;
    private LoginExpandModel loginData;
}
